import Vue from 'vue'
import Vuex from 'vuex'
import * as actions from './actions'
import * as getters from './getters'
import hotspot from './modules/hotspot'
import weather from './modules/weather'
import map from './modules/map'
import createLogger from './plugins/logger'

Vue.use(Vuex)

const debug = process.env.NODE_ENV !== 'production'

export default new Vuex.Store({
  actions,
  getters,
  modules: {
    hotspot,
    map,
    weather,
  },
  strict: debug,
  plugins: debug ? [createLogger()] : []
})
